{% extends "base.html" %}
{% block title %}登录{% endblock %}
{% block styles %}
    {{ super() }}

{% endblock %}
{% block page_content %}
    <form action="/user/login?next={{ next }}" method="post" class="form-horizontal col-sm-offset-3 col-md-offset-3">
        <h3 class="form-title">用户登录</h3>
        <div class="col-sm-9 col-md-9">
            <div class="form-group">
                {{ form.username.label }}
                {% for msg in form.username.errors %}<small class="errors">{{ msg }}</small><br>{% endfor %}
                {{ form.username() }}
            </div>

            <div class="form-group">
                {{ form.password.label }}
                {% for msg in form.password.errors %}<small class="errors">{{ msg }}</small><br>{% endfor %}
                {{ form.password() }}
            </div>
            <div class="form-group">
                <a href="{{ url_for('user_register') }}">注册</a>
                {{ form.submit() }}
            </div>
        </div>
    </form>

{% endblock %}
